package com.example.base.Cache;

public interface Cache {


    public static final String SEPERATOR = ":";

    public static final String DEFAULT_FIELD = "DF";

    public abstract Object get(String key);

    public abstract Object hGet(String key, String field);

    public abstract Object hGet(String key, String extKey, String field);

    public abstract Object hGet(Class<?> clazz, String field);

    public abstract Object hGet(Class<?> clazz, String extKey, String field);

    public abstract void set(CacheKey obj);

    public abstract void set(String key, Object o);

    public abstract void set(String key, Object o, int ex);

    public abstract void hSet(String key, String field, Object o);

    public abstract void hSet(CacheKey obj, String extKey, String field);

    public abstract void del(CacheKey o);

    public abstract void del(String key);

    public abstract void del(Class<? extends CacheKey> clazz);

    public abstract void del(Class<? extends CacheKey> clazz, String extKey);

    public abstract void hDel(Class<? extends CacheKey> clazz, String field);

    public abstract void hDel(Class<? extends CacheKey> clazz, String extKey, String field);
}
